package cn.tedu.yushouge.pet.adopt.pojo.param;

import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.experimental.Accessors;
import org.hibernate.validator.constraints.Range;

import javax.validation.constraints.NotNull;
import java.time.LocalDate;
import java.time.LocalDateTime;

@Data
@Accessors(chain = true)
public class AdoptUpdateInfoParam {

    @ApiModelProperty(value = "用户ID", required = true, example = "98")
    private Long userId;

    @NotNull(message = "修改宠物领养失败，必须提交宠物ID！")
    @ApiModelProperty(value = "宠物ID", required = true, example = "88")
    private Long petId;

    @NotNull(message = "修改宠物领养失败，必须提交宠物领养登记时间！")
    @ApiModelProperty(value = "宠物领养登记时间", required = true, example = "2021年12月28日")
    private LocalDate applyTime;

    @NotNull(message = "修改宠物领养失败，必须提交宠物领养原因！")
    @ApiModelProperty(value = "宠物领养申请原因", required = true, example = "2021年12月28日")
    private String cause;

    @NotNull(message = "修改宠物领养失败，必须提交宠物领养状态！")
    @Range(max = 1, message = "修改宠物领养失败，宠物领养状态只能是0或者1！")
    @ApiModelProperty(value = "宠物领养状态", required = true, example = "1")
    private Integer state;

    @NotNull(message = "修改宠物领养失败，必须提交排序序号！")
    @Range(max = 99, message = "修改宠物领养失败，排序序号值必须0~99之间！")
    @ApiModelProperty(value = "排序序号，必须是1~99之间的数字", required = true, example = "97")
    private Integer sort;

}
